<%@ page language="java" contentType="text/html; charset=UTF-8" 
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<style>
a,a:visited{color: white; text-decoration:none}
</style>
</head>

<body>
   <div style=" width:800px; height:400px; margin:auto; background:#0CC; ">
     <div style=" background-color:#399; width:400px; height:200px; margin:auto ; padding:5px; border:#069 solid 2px; position:relative; top:100px;">
      <form action="logon.do" method="post">
      <label style=" font-family:华文彩云; color:white; font-size:32px; margin:5px;">用户登录</label>
      <hr style="border:#369 dotted 1px;"/>
      <!---------------------------------------------------------------------------->
          <table width="400" border="0" align="center" style="font-size:14px; color:white;">
  <tr>
    <td width="77" rowspan="3"><img src="img/logon.jpg"/></td>
    <td width="59" height="27">用户名</td>
    <td width="68"><input type="text" name="regName"/></td>
    <td width="78">&nbsp;</td>
  </tr>
  <tr>
    <td height="27">密码</td>
    <td><input type="password" name="pwd"/></td>
    <td><a href="">忘记密码？</a></td>
  </tr>
  <tr>
    <td>验证码</td>
    <td><input type="text" name="code"/></td>
    <td>
<%
	int ran = (int)(Math.random()*10000);
	String code = String.valueOf(ran);
	session.setAttribute("code",code);
	out.print(code);
%>
</td>
  </tr>
  <tr>
  <td></td>
  <td colspan = "2">10天免登录<input type="checkbox" name="ten" value="auto"/>
  </td>
  </tr>
  <tr>
    <td colspan="4" style=" text-align:center">
    <button type="button" onclick="location='reg_protocal'">注册</button>
    <button type="button" onclick="toLogon();">登录</button>
    
    <label style="color:red">
<%--     <%=request.getAttribute("msg")!=null?request.getAttribute("msg"):"" %> --%>
    ${msg }</label>
    </td>
    </tr>
</table>
</form>
      <script>
        function toLogon(){
        	
        	
        	
        	document.forms[0].submit();
        }
      </script>
      
      <!---------------------------------------------------------------------------->
      </div>
   
   </div>
    <div style=" width:800px; height:60px; margin:auto; background-color:#039; position:relative;padding-top:20px; padding-bottom:20px;">
         <p  style=" color:white; text-align:center; ">
              版权所有........................
         </p>
   </div>


</body>
</html>
